package com.mg.framework.tiled;

import java.util.Properties;

public class MapObject {

	private Properties properties;
	private ObjectGroup objectGroup;
	private Rectangle bounds;
	private String name;
	private String type;

	public MapObject(int x, int y, int width, int height) {
		this.properties = new Properties();
		this.objectGroup = null;
		this.name = "Object";
		this.bounds = new Rectangle(x, y, width, height);
	}
	
	public int getX(){
		return this.bounds.x;
	}
	
	public int getY(){
		return this.bounds.y;
	}

	public void setName(String name) {
		this.name = name;
	}
	
	public String getName(){
		return this.name;
	}

	public void setType(String type) {
		this.type = type;
	}

	public void setProperties(Properties props) {
		properties = props;
	}
	
	public void setObjectGroup(ObjectGroup objectGroup) {
		this.objectGroup = objectGroup;
	}
	
	public boolean isMe(String name){
		return this.name.equals(name);
	}
}
